﻿/*
using Project.API.Models;
using Project.BLL;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;

namespace Project.API.Controllers.OrdersControllers
{
    public class OrdersController : ApiController
    {
        // GET api/<controller>

        public ResultData<List<OrdersDto>> Get(int id)
        {
            int count = 0;
            var list = new OrdersBll().GetUsers(id);
            var roles = new OrdersBll().Query();
            var data = from u in list
                       select new OrdersDto
                       {
                           Did = u.Did,
                           UserId = (int)u.UserId,
                           Gpvid = (int)u.Gpvid,
                           CreateDate = u.CreateDate,
                           OrderNumber = (int)u.OrderNumber,
                           TotalAmount = (int)u.TotalAmount,
                           OrderStatus = u.OrderStatus,
                           Notes = u.Notes
                       };
            ResultData<List<OrdersDto>> result = new ResultData<List<OrdersDto>>();
            result.code = 0;
            result.msg = "ok";
            result.data = data.ToList();
            return result;
        }

        public IEnumerable<string> Get()
        {
            return new string[] { "value1", "value2" };
        }

        // GET api/<controller>/5

        // POST api/<controller>
        public void Post([FromBody] string value)
        {
        }

        // PUT api/<controller>/5
        public void Put(int id, [FromBody] string value)
        {
        }

        // DELETE api/<controller>/5
        public void Delete(int id)
        {
        }
    }
}*/